package DoThiThuyDiem_10130115_BTLCMCB;


import java.io.File;

public class DeleteDir {
	public static boolean deletdeDir(String path) {
		File dir = new File(path);
		if (!dir.exists())
			return false;
		if (dir.isFile())
			return dir.delete();
		if (!dir.isDirectory())
			return false;
		File[] list = dir.listFiles();
		if(list == null)return false;
		for (File f : list)
			deletdeDir(f.getAbsolutePath());

		return dir.delete();

	}
	public static void main(String[] args) {
		String dir = "E:\\ABC\\";
		deletdeDir(dir);
		
	}
}

